package com.cn.designpatterns.ex.again.ex.discount;

/**
 * @author: zhangyi
 * @date: 2019/1/8 11:42
 * @description:
 */
public class Discount {
    public static void main(String[] args) {
        Discou discou = new SuperMark(1000);
        double count = discou.count(0.7);
        System.out.println(count);
    }
}

interface Discou{

    double count(double disCount);
    double norCount();
}
class SuperMark implements Discou{
    private double choseCount;

    public SuperMark(double choseCount) {
        this.choseCount = choseCount;
    }

    @Override
    public double count(double disCount) {
        return choseCount*disCount;
    }

    @Override
    public double norCount() {
        return choseCount;
    }
}